This project shows how the user can detect via software a "/01 Revision" part for the LPC21xx/22xx and LPC2104/5/6 devices.
The serial port (UART0 or UART1) is used as a Console (using Hyperterminal) so a message can be shown in a PC.
The Hyperterminal must be configured with 9600,8,N,1,None (flow control)
A variable (rev) is defined to hold the result, so debugging the program and inspecting its value, can be used
to recognize the part;

      rev = -1		//  the test has not begun yet
	  rev =  0		//  the part is an "old" part
	  rev =  1		//  the part is a "/01" part

In addition, the variable can be used to take the desired actions in the user application software.
After the revision detection test, P0.4 is used to blink a led as an "board activity" indicator.


Revision Detection Algorithm used:
The "/01" revision devices incorporate an autobaud feature for the UARTs. This new register may be used to differentiate
them from the "old" parts.  Bit 1 (Mode bit) of the UxACR register must be written with both a '1' and a '0' value. Verifying 
(reading back the same value) each of the above operations will help us to test the revision. That is, for the old parts, 
where this register doesn't exist, one of the above operations will fail. If neither operations failed, that means the register
exist, so there is a /01 revision part.

 

